package com.jiachunlei.sso.controller;

import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

import java.security.Principal;

/**
 * @author 朝花不迟暮
 * @version 1.0
 * @date 2020/11/1 16:07
 */
@RestController
public class UserController
{
    @GetMapping("/user")
    public Principal getCurrentUser(Principal principal)
    {
        return principal;
    }
}
